package com.evony.common.server.events 
{
    import com.evony.common.*;
    import com.evony.common.beans.*;
    
    public class AcademyResearchUpdate extends com.evony.common.BaseBean
    {
        public function AcademyResearchUpdate(arg1:String, arg2:Object, arg3:Boolean=false, arg4:Boolean=false)
        {
            var loc1:*=0;
            super(arg1, arg3, arg4);
            if (arg2.castleId != null) 
            {
                this.castleId = arg2.castleId;
            }
            if (arg2.researchBean != null) 
            {
                this.researchBean = new com.evony.common.beans.AvailableResearchListBean(arg2.researchBean);
            }
            return;
        }

        public function copyTo(arg1:com.evony.common.server.events.AcademyResearchUpdate):void
        {
            arg1.castleId = this.castleId;
            if (researchBean == null) 
            {
                arg1.researchBean = null;
            }
            else 
            {
                this.researchBean.copyTo(arg1.researchBean);
            }
            return;
        }

        public function toObject():Object
        {
            var loc1:*=new Object();
            loc1.castleId = this.castleId;
            loc1.researchBean = this.researchBean.toObject();
            return loc1;
        }

        public override function toDebugString(arg1:String=""):String
        {
            var loc1:*=0;
            var loc2:*="---- AcademyResearchUpdate ----\n";
            loc2 = loc2 + (arg1 + "castleId = " + this.castleId + "\n");
            if (researchBean == null) 
            {
                loc2 = loc2 + (arg1 + "researchBean = null\n");
            }
            else 
            {
                loc2 = loc2 + this.researchBean.toDebugString(arg1 + "researchBean.");
            }
            return loc2;
        }

        public var castleId:int;

        public var researchBean:com.evony.common.beans.AvailableResearchListBean;
    }
}
